
module.exports = app => {
    const { DATE, STRING, JSON } = app.Sequelize;
    const User = app.model.define('b_c_user', {
        //id: { type: INTEGER(11), primaryKey: true, autoIncrement: true },
        username: { type: STRING(255), primaryKey: true, allowNull: false },
        password: { type: STRING(255), allowNull: false },
        group_name: { type: STRING(255), allowNull: false },
        //role_name: { type: STRING(255), allowNull: false },
        roles: { type: JSON, allowNull: false },
        realName:{type: STRING(255), allowNull: false ,defaultValue:''},
        desc: { type: STRING(255), allowNull: true ,defaultValue:'https://q1.qlogo.cn/g?b=qq&nk=190848757&s=640'},
        homePath: { type: STRING(255), allowNull: true },
        created_at: { type: DATE, allowNull: false, defaultValue: new Date() },
        updated_at: { type: DATE, allowNull: false, defaultValue: new Date() },
    }, {
        paranoid: false,
        timestamps: true,
    });

    return User;
};
export { }


